package com.apes.framework.plugin.scheduler;


import com.apes.framework.api.SpringManager;
import com.apes.framework.rop.event.RopListener;
import com.apes.oap.event.AfterStartedRopEvent;
import com.apes.oap.event.RopEventListener;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

/**
 * 功能：EsbEvent RopListener
 *
 * @author xul
 * @create 2017-12-05 14:05
 */
@RopListener
public class ScheduleEventListener implements RopEventListener<AfterStartedRopEvent> {
    protected final Logger logger = LogManager.getLogger(ScheduleEventListener.class);

    public void onRopEvent(AfterStartedRopEvent ropRopEvent) {
        SpringManager.getBean(TaskScheduler.class).start();
    }

    public int getOrder() {
        return 300;
    }
}

